package com.senthink.gl.business.device;

import com.fasterxml.jackson.annotation.JsonInclude;
import lombok.Data;
import org.hibernate.validator.constraints.NotBlank;

/**
 * 接口传递的控制计量插座的Request
 *
 * @author zooqi@senthink.com
 * @date 2018/01/10
 */
@Data
@JsonInclude(JsonInclude.Include.NON_NULL)
public class CmdRequest {

    /**
     * 区域唯一业务ID
     */
    @NotBlank(groups = {AreaToggleGroup.class})
    private String aid;

    /**
     * 计量插座ID
     */
    @NotBlank(groups = {ToggleGroup.class})
    private String measureSocketId;

    /**
     * 开关命令
     */
    @NotBlank(groups = {ToggleGroup.class, AreaToggleGroup.class})
    private String command;

    public interface ToggleGroup {
    }

    public interface AreaToggleGroup {
    }
}
